package c.e.a.b.f.b;

import android.os.RemoteException;
import c.e.a.b.e.c.hc;
import com.google.android.gms.measurement.internal.zzaq;

/* compiled from: com.google.android.gms:play-services-measurement-impl@@18.0.0 */
public final class c8 implements Runnable {
    public final /* synthetic */ zzaq a;
    public final /* synthetic */ String b;
    public final /* synthetic */ hc c;
    public final /* synthetic */ q7 d;

    public c8(q7 q7Var, zzaq zzaq, String str, hc hcVar) {
        this.d = q7Var;
        this.a = zzaq;
        this.b = str;
        this.c = hcVar;
    }

    public final void run() {
        byte[] bArr = null;
        try {
            q7 q7Var = this.d;
            i3 i3Var = q7Var.d;
            if (i3Var == null) {
                q7Var.d().f.a("Discarding data. Failed to send event to service to bundle");
                return;
            }
            bArr = i3Var.Z(this.a, this.b);
            this.d.F();
            this.d.k().P(this.c, bArr);
        } catch (RemoteException e) {
            this.d.d().f.b("Failed to send event to the service to bundle", e);
        } finally {
            this.d.k().P(this.c, bArr);
        }
    }
}
